package dataflowscheme.engine.core;

import java.util.concurrent.LinkedBlockingQueue;

import org.apache.log4j.Logger;

/**
 * Encapsulate data-flow Task entity.
 * 
 * @author <a href="mailto:misiak7@gmail.com">Michal Antolik</a>
 *
 */
public class CTask extends PE{

	static Logger log = Logger.getLogger(CTask.class);
	
	public CTask(dataflowScheme.Task etask, LinkedBlockingQueue<IEvent> queue, LinkedBlockingQueue<IExecutionEvent> executionQueue){
		super(etask, queue, executionQueue);
	}

	/**
	 * start new execution
	 */
	protected void schedule(int portset) {
		IExecutionEvent event = new TaskExecutionEvent(this, portset);
		executionQueue.offer(event);
	}

}
